package com.project.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.project.bean.PostsBean;
import com.project.bean.ReplayBean;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.time.LocalDate;
import java.util.List;

@Mapper
public interface IPostsMapper extends BaseMapper<PostsBean> {
    public IPage<PostsBean> selectByItem(Page page, @Param("theme") String theme, @Param("author") String author,
                                         @Param("startDate") LocalDate startDate, @Param("endDate") LocalDate endDate,@Param("channelId") Integer channelId);
    public List<ReplayBean> selectReplays(Integer id);

    public PostsBean selectPosts(Integer id);
}
